
//
//  MyTapBiResuleTableViewCell.m
//  VEMoneyPorject
//
//  Created by 陈建 on 2018/9/28.
//  Copyright © 2018年 陈建. All rights reserved.
//

#import "MyTapBiResuleTableViewCell.h"

@implementation MyTapBiResuleTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self setupUI];
    }
    return self;
}

- (void)setupUI{
    self.contentView.backgroundColor = [UIColor whiteColor];
    CGFloat btnW = kScreenWidth/3.0;
    UILabel *lab1 = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, btnW, 40)];
    [self.contentView addSubview:lab1];
     lab1.textAlignment = NSTextAlignmentCenter;
    lab1.textColor = [UIColor colorWithHexString:kDetailTextBlackColor];
    lab1.font = kFont(14.f);
    self.lab1 = lab1;
    
    UILabel *lab2 = [[UILabel alloc] initWithFrame:CGRectMake(btnW, 0, btnW, 40)];
    [self.contentView addSubview:lab2];
     lab2.textAlignment = NSTextAlignmentCenter;
    lab2.textColor = [UIColor colorWithHexString:kDetailTextBlackColor];
    lab2.font = kFont(14.f);
    self.lab2= lab2;
    RankButton *btn = [[RankButton alloc] initWithFrame:CGRectMake(2*btnW, 0, btnW, 40)];
    btn.titleLabel.textAlignment = NSTextAlignmentCenter;
    [btn setImage:IMG(@"上拉1") forState:UIControlStateNormal];
    btn.type = buttonTypePicRight;
    btn.picTileRange = 5;
    [btn setTitleColor:[UIColor colorWithHexString:kNomalTextBlackColor] forState:UIControlStateNormal];
    [btn addTarget:self action:@selector(btnClick) forControlEvents:UIControlEventTouchUpInside];
    [self.contentView addSubview:btn];
    self.btn = btn;
    
    UIView *bottomView = [[UIView alloc] initWithFrame:CGRectMake(0, 40, kScreenWidth, 10)];
    bottomView.backgroundColor = [UIColor colorWithHexString:kCommonBgColor];
    [self.contentView addSubview:bottomView];
    
    
}

- (void)btnClick{
    if (self.TapBtnBlock) {
        self.TapBtnBlock();
    }
}

@end
